package mrms.api.web.authentication;

import org.springframework.util.DigestUtils;

/**
 * @author lenchu
 * @date 2019/01/31
 */
public class Encipher {
    public static String encryptJwtSecretWithPasswordAndSecret(String password, String secret) {
        return encryptPasswordWithMD5(password + secret);
    }

    public static String encryptPasswordWithMD5(String password) {
        return DigestUtils.md5DigestAsHex(password.getBytes());
    }
}
